 cmake_minimum_required(VERSION 3.10 FATAL_ERROR)
project(test)
find_package(OpenCV 4.4 REQUIRED)
include_directories(${OpenCV_INCLUDE_DIRS})#包含路径
link_directories(${OpenCV_LIBRARY_DIRS})#设置目录
add_executable(test test.cpp)
target_link_libraries(test ${OpenCV_LIBRARIES})
